﻿using Common;
using PLC.Domain.Dto;
using PLC.Domain.Enum;
using PLC.Domain.Models;

namespace PLC.Domain.ScheduledTasks.Strategy.Trigger;

public class KeepConnectionStrategy:BaseTrigger
{
    public override EnumTrigger EnumTrigger { get; protected set; } = EnumTrigger.保持通讯;
    public override int TriggerEvent(PLCConfig plcConfig, DtoDataConfig trigger, PLCReadModel plcReadModel)
    {
        return plcReadModel.TestConnection.ToInt32();
    }
}